package cn.zhiquxing.aop;

import org.aspectj.lang.annotation.After;
import org.aspectj.lang.annotation.AfterReturning;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.springframework.stereotype.Component;

//@Aspect
//@Component
public class MyAsepct {
    
    private static final String aopExp = "execution(* *(..))";
    
    @Before(aopExp)
    public void before() {
        System.out.println("aop before");
    }
    
    @After(aopExp)
    public void after() {
        System.out.println("aop after");
    }
    
    @AfterReturning
    public void afterReturning() {
        System.out.println("aop afterReturning");
    }
}
